package com.kbbywyclient.data.entity;

import android.text.TextUtils;

import com.kbbywyclient.app.Constants;

import java.util.List;
import java.util.Locale;

/**
 * Created by Jiangzx on 2017/11/2 19:46.
 */

public class ClerkDetailsData {
    private String all_include;//进件总数
    private String all_settlement;//结算总数
    private String all_upper_prize_amount;//总奖金数
    private String count;//总人数

    private List<MonthData> every_month;

    public String getAll_include() {
        return all_include;
    }

    public void setAll_include(String all_include) {
        this.all_include = all_include;
    }

    public String getAll_settlement() {
        return all_settlement;
    }

    public void setAll_settlement(String all_settlement) {
        this.all_settlement = all_settlement;
    }

    public String getAll_upper_prize_amount() {
        return all_upper_prize_amount;
    }

    public void setAll_upper_prize_amount(String all_upper_prize_amount) {
        this.all_upper_prize_amount = all_upper_prize_amount;
    }

    public String getCount() {
        return count;
    }

    public void setCount(String count) {
        this.count = count;
    }

    public List<MonthData> getEvery_month() {
        return every_month;
    }

    public void setEvery_month(List<MonthData> every_month) {
        this.every_month = every_month;
    }

    public static class MonthData{
        /**
         * every_month : 2017年09月
         * include_num : 2
         * settlement_num : 5
         * upper_prize_amount : 30
         */

        private String every_month;
        private String include_num;//进件总数
        private String settlement_num;//结算总数
        private String upper_prize_amount;//总奖金数

        public String getEvery_month() {
            return every_month;
        }

        public void setEvery_month(String every_month) {
            this.every_month = every_month;
        }

        public String getInclude_num() {
            return include_num;
        }

        public void setInclude_num(String include_num) {
            this.include_num = include_num;
        }

        public String getSettlement_num() {
            return settlement_num;
        }

        public void setSettlement_num(String settlement_num) {
            this.settlement_num = settlement_num;
        }

        public String getUpper_prize_amount() {
            if(TextUtils.isEmpty(this.upper_prize_amount)){
                return "0.00";
            }
            return String.format(Locale.CHINESE,
                    Constants.AMOUNT_FORMAT,
                    Double.parseDouble(upper_prize_amount));
        }

        public void setUpper_prize_amount(String upper_prize_amount) {
            this.upper_prize_amount = upper_prize_amount;
        }
    }
}
